<extend name="Base/common"/>
<block name="style">
     <link href="__CSS__/jxgl.css" type="text/css" rel="stylesheet">
</block>
<block name="header">
    <include file="Public/_nav"/>
</block>
<block name="body">

      <!--   <include file="Public/_hot_sell"/> -->
        <!-- 左侧菜start -->
        <div class="col-md-2 col-xs-3">            
             <div class="common_block_border">                
                <div class="content ">
                <include file="Public/sidebar"  />
                </div>
            </div>
        </div>
        <!-- 左侧菜end -->

        <!-- 右侧内容开始 -->
        <div class="col-md-10 col-xs-9">
        <div class="common_block_border">
        <ul class="nav nav-tabs">
          <li><a href="{:U('Xshj/index')}">学生获奖登记</a></li>
          <li class="active"><a href="{:U('Xshj/hjhz')}">学生获奖情况汇总</a></li>
          <if condition="check_auth('Admin/Index/index')"><li><a href="{:U('Xshj/cate')}">获奖等级设置</a></li></if>
        </ul>
        <div class="tab-content">
          <!-- 查询表单start -->
            <div class="right_box">
                <form method='post' id="form1" name="form1"  action="{:U('Xshj/hjhz')}" class="form-horizontal form-condensed">
                  <div class="col-md-8">
                   <div class="form-group">
                                 <div class="input-group">
                                    <span class="input-group-addon">学年</span>
                                            <select name="year" id="year" class="form-control">
                                               <option value="" <if condition="$year eq $y['year']">selected</if> >所有学年</option>
                                               <volist name='yearlist' id='y'>
                                               <option value="{$y.year}" <if condition="$year eq $y['year']">selected</if> >{$y.year}学年</option> 
                                               </volist>           
                                            </select> 
                                    
                                    <span class="input-group-addon fix-border fix-padding"> 教师</span>
                                     <input type="text" class="form-control" name="teacher" value="{$teacher}" placeholder="按指导教师姓名查询">

                                     <span class="input-group-addon fix-border fix-padding"> 学生</span>
                                     <input type="text" class="form-control" name="st_name" value="{$st_name}" placeholder="按学生姓名查询">
                                    <span class="input-group-btn">
                                      <button class="btn btn-primary" type="submit">&nbsp;查询&nbsp;</button>
                                    </span>
                              </div>
                              </div> 
                        </div>
                   <div class="col-md-2">

                  <if condition="check_auth('Admin/Index/index')">
                  <a href="{:U('Xshj/excel_2')}" class="btn btn-danger ">&nbsp;导出汇总金额&nbsp;</a></div>
                  </if>
                  <a href="{:U('Xshj/excel_out')}" class="btn btn-success ">&nbsp;导出&nbsp;Excel汇总表&nbsp;</a></div>
              </form> 
           
                <!-- 查询表单end -->
       <!-- 数据表格开始 -->
             <div class="right_box">
             {$thisyear}
                <table class="table table-bordered">
                 <COL width="35px"></COL>
                 <COL width="80px"></COL>
                 <COL width="80px"></COL>
                 <COL width="80px"></COL>
                 <COL width="80px"></COL>
                 <COL width="30%"></COL>
                 <COL width="80px"></COL>
                  <thead>
                    <tr>
                      <th class="text-center">#</th>
                      <th class="text-center">获奖日期</th>
                      <th class="text-center">班级</th>
                      <th class="text-center">学生</th>
                      <th class="text-center">获奖等级</th>            
                      <th class="text-center">获奖内容</th>
                      <th class="text-center">辅导教师</th>
                      <th class="text-center">登记日期</th> 
                      <th class="text-center">操作</th>
                    </tr>
                  </thead>
                  <tbody>
                  <volist name='list' id='vo'>
                    <tr>
                      <td>{$i}</td>
                      <td>
                      <if condition="($vo.status neq 1)"> 
                      <span style="color:red"> {$vo.date}</span>
                       <else/>
                      {$vo.date}
                      </if>
                      </td>            
                      <td>{$vo.class}</td>
                      <td>{$vo.student}</td>
                      <td>{$vo.hjdj}</td>
                      

                      <td>{$vo.content}</td>
                      <td>{$vo.teacher}</td>
                      <td>{$vo.create_time|date="Y-m-d",###}</td> 
                      <td><a href="{:U('Xshj/edit?id='.$vo['id'])}" ><i class="icon icon-edit"></i></a>｜
                          <a href= "{:U('Xshj/delete?id='.$vo['id'])}" onclick="return confirm('删除后不可恢复，你确认要删除吗？')"><i class="icon icon-trash"></i></a></td>
                    </tr>
                    </volist>
                  </tbody>
                </table>
                <!-- 数据表格end -->
                <!-- 分页 -->
               <div class="text-right"> 
                {:getPagination($totalPageCount,$r)}
                </div>
              <!-- 分页 -->
              </div> 
            </div>
        </div>
    </div>
  <!-- 右侧内容结束 -->  
 

   
</block>
